using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._3DAnalystTools._Raster._Surface
{
    /// <summary>
    /// <para>Contour with Barriers</para>
    /// <para>Creates contours from a raster surface. The inclusion of barrier features allows you to independently generate contours on either side of a barrier.</para>
    /// <para>从栅格表面创建等值线。通过包含屏障特征，您可以在屏障的任一侧独立生成等值线。</para>
    /// </summary>    
    [DisplayName("Contour with Barriers")]
    public class ContourWithBarriers : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public ContourWithBarriers()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_in_raster">
        /// <para>Input Raster</para>
        /// <para>The input surface raster.</para>
        /// <para>输入表面栅格。</para>
        /// </param>
        /// <param name="_out_contour_feature_class">
        /// <para>Output Contour Features</para>
        /// <para>The output contour features.</para>
        /// <para>输出轮廓特征。</para>
        /// </param>
        public ContourWithBarriers(object _in_raster, object _out_contour_feature_class)
        {
            this._in_raster = _in_raster;
            this._out_contour_feature_class = _out_contour_feature_class;
        }
        public override string ToolboxName => "3D Analyst Tools";

        public override string ToolName => "Contour with Barriers";

        public override string CallName => "3d.ContourWithBarriers";

        public override List<string> AcceptEnvironments => ["MDomain", "MResolution", "MTolerance", "XYDomain", "XYResolution", "XYTolerance", "ZDomain", "ZResolution", "ZTolerance", "autoCommit", "configKeyword", "extent", "geographicTransformations", "maintainSpatialIndex", "outputCoordinateSystem", "outputMFlag", "outputZFlag", "outputZValue", "scratchWorkspace", "workspace"];

        public override object[] ParameterInfo => [_in_raster, _out_contour_feature_class, _in_barrier_features, _in_contour_type.GetGPValue(), _in_contour_values_file, _explicit_only.GetGPValue(), _in_base_contour, _in_contour_interval, _in_indexed_contour_interval, _in_contour_list, _in_z_factor];

        /// <summary>
        /// <para>Input Raster</para>
        /// <para>The input surface raster.</para>
        /// <para>输入表面栅格。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Raster")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_raster { get; set; }


        /// <summary>
        /// <para>Output Contour Features</para>
        /// <para>The output contour features.</para>
        /// <para>输出轮廓特征。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Contour Features")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _out_contour_feature_class { get; set; }


        /// <summary>
        /// <para>Input Barrier Features</para>
        /// <para><xdoc>
        ///   <para>The input barrier features.</para>
        ///   <para>The features can be polyline or polygon type.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>输入屏障功能。</para>
        ///   <para>要素可以是折线类型或面类型。</para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Barrier Features")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _in_barrier_features { get; set; } = null;


        /// <summary>
        /// <para>Type of Contours</para>
        /// <para><xdoc>
        ///   <para>The type of contour to create.</para>
        ///   <bulletList>
        ///     <bullet_item>Polylines— The contour or isoline representation of the input raster.</bullet_item><para/>
        ///     <bullet_item>Polygons— Closed polygons representing the contours.</bullet_item><para/>
        ///   </bulletList>
        ///   <para>The current version of this tool only supports polyline output. If the polygon output option is used, it will be ignored and polyline output will be created.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>要创建的轮廓类型。</para>
        ///   <bulletList>
        ///     <bullet_item>折线 - 输入栅格的等值线或等值线表示。</bullet_item><para/>
        ///     <bullet_item>多边形 — 表示等高线的闭合多边形。</bullet_item><para/>
        ///   </bulletList>
        ///   <para>此工具的当前版本仅支持折线输出。如果使用多边形输出选项，则将忽略该选项并创建多边形输出。</para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Type of Contours")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _in_contour_type_value _in_contour_type { get; set; } = _in_contour_type_value._POLYLINES;

        public enum _in_contour_type_value
        {
            /// <summary>
            /// <para>Polylines</para>
            /// <para>Polylines— The contour or isoline representation of the input raster.</para>
            /// <para>折线 - 输入栅格的等值线或等值线表示。</para>
            /// </summary>
            [Description("Polylines")]
            [GPEnumValue("POLYLINES")]
            _POLYLINES,

            /// <summary>
            /// <para>Polygons</para>
            /// <para>Polygons— Closed polygons representing the contours.</para>
            /// <para>多边形 — 表示等高线的闭合多边形。</para>
            /// </summary>
            [Description("Polygons")]
            [GPEnumValue("POLYGONS")]
            _POLYGONS,

        }

        /// <summary>
        /// <para>File Containing Contour Value Specifications</para>
        /// <para>The base contour, contour interval, indexed contour interval, and explicit contour values can also be specified via a text file.</para>
        /// <para>还可以通过文本文件指定基本等值线、等值线间隔、索引等值线间隔和显式等值线值。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("File Containing Contour Value Specifications")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _in_contour_values_file { get; set; } = null;


        /// <summary>
        /// <para>Enter Explicit Contour Values Only</para>
        /// <para><xdoc>
        ///   <para>Only explicit contour values are used. Base contour, contour interval, and indexed contour intervals are not specified.</para>
        ///   <bulletList>
        ///     <bullet_item>Unchecked—The default, contour interval must be specified.</bullet_item><para/>
        ///     <bullet_item>Checked—Only explicit contour values are specified.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>仅使用显式等值线值。未指定基础等值线、等值线间隔和索引等值线间隔。</para>
        ///   <bulletList>
        ///     <bullet_item>未选中 （Unchecked） - 必须指定缺省等值线间隔。</bullet_item><para/>
        ///     <bullet_item>选中 （Checked） - 仅指定显式等值线值。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Enter Explicit Contour Values Only")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _explicit_only_value _explicit_only { get; set; } = _explicit_only_value._false;

        public enum _explicit_only_value
        {
            /// <summary>
            /// <para>EXPLICIT_VALUES_ONLY</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("EXPLICIT_VALUES_ONLY")]
            [GPEnumValue("true")]
            _true,

            /// <summary>
            /// <para>NO_EXPLICIT_VALUES_ONLY</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("NO_EXPLICIT_VALUES_ONLY")]
            [GPEnumValue("false")]
            _false,

        }

        /// <summary>
        /// <para>Base Contour</para>
        /// <para><xdoc>
        ///   <para>The base contour value.</para>
        ///   <para>Contours are generated above and below this value as needed to cover the entire value range of the input raster. The default is zero.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>基本等值线值。</para>
        ///   <para>根据需要在此值上方和下方生成等值线，以覆盖输入栅格的整个值范围。默认值为零。</para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Base Contour")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public double _in_base_contour { get; set; } = 0;


        /// <summary>
        /// <para>Contour Interval</para>
        /// <para><xdoc>
        ///   <para>The interval, or distance, between contour lines.</para>
        ///   <para>This can be any positive number.</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>等值线之间的间隔或距离。</para>
        ///   <para>这可以是任何正数。</para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Contour Interval")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public double? _in_contour_interval { get; set; } = null;


        /// <summary>
        /// <para>Indexed Contour Interval</para>
        /// <para>Contours will also be generated for this interval and will be flagged accordingly in the output feature class.</para>
        /// <para>还将为此区间生成等值线，并将在输出要素类中相应地进行标记。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Indexed Contour Interval")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public double _in_indexed_contour_interval { get; set; } = 0;


        /// <summary>
        /// <para>Explicit Contour Values</para>
        /// <para>Explicit values at which to create contours.</para>
        /// <para>用于创建轮廓的显式值。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Explicit Contour Values")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public List<object> _in_contour_list { get; set; } = null;


        /// <summary>
        /// <para>Factor Applied to Raster Z-values</para>
        /// <para><xdoc>
        ///   <para>The unit conversion factor used when generating contours. The default value is 1.</para>
        ///   <para>The contour lines are generated based on the z-values in the input raster, which are often measured in units of meters or feet. With the default value of 1, the contours will be in the same units as the z-values of the input raster. To create contours in a unit other than that of the z-values, set an appropriate value for the z-factor. It is not necessary to have the ground x,y and surface z-units be consistent for this tool.</para>
        ///   <para>For example, if the elevation values in your input raster are in feet, but you want the contours to be generated based on units of meters, set the z-factor to 0.3048 (since 1 foot = 0.3048 meter).</para>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>生成等值线时使用的单位转换系数。默认值为 1。</para>
        ///   <para>等值线是根据输入栅格中的 z 值生成的，z 值通常以米或英尺为单位进行测量。默认值为 1 时，等值线的单位将与输入栅格的 z 值相同。要以 z 值以外的单位创建等值线，请为 z 因子设置适当的值。对于此工具，不必使地面 x，y 和表面 z 单位保持一致。</para>
        ///   <para>例如，如果输入栅格中的高程值以英尺为单位，但您希望基于米单位生成等值线，请将 z 因子设置为 0.3048（因为 1 英尺 = 0.3048 米）。</para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Factor Applied to Raster Z-values")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public double _in_z_factor { get; set; } = 1;


        public ContourWithBarriers SetEnv(object MDomain = null, object MResolution = null, object MTolerance = null, object XYDomain = null, object XYResolution = null, object XYTolerance = null, object ZDomain = null, object ZResolution = null, object ZTolerance = null, int? autoCommit = null, object configKeyword = null, object extent = null, object geographicTransformations = null, bool? maintainSpatialIndex = null, object outputCoordinateSystem = null, object outputMFlag = null, object outputZFlag = null, object outputZValue = null, object scratchWorkspace = null, object workspace = null)
        {
            base.SetEnv(MDomain: MDomain, MResolution: MResolution, MTolerance: MTolerance, XYDomain: XYDomain, XYResolution: XYResolution, XYTolerance: XYTolerance, ZDomain: ZDomain, ZResolution: ZResolution, ZTolerance: ZTolerance, autoCommit: autoCommit, configKeyword: configKeyword, extent: extent, geographicTransformations: geographicTransformations, maintainSpatialIndex: maintainSpatialIndex, outputCoordinateSystem: outputCoordinateSystem, outputMFlag: outputMFlag, outputZFlag: outputZFlag, outputZValue: outputZValue, scratchWorkspace: scratchWorkspace, workspace: workspace);
            return this;
        }

    }

}